.page-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 200px;
  
  &.ant-spin-spinning {
    max-height: none;
  }
  
  .ant-spin-text {
    margin-top: 8px;
    font-size: 14px;
    color: rgba(0, 0, 0, 0.65);
  }
  
  &.page-loading-transparent {
    background-color: transparent;
  }
  
  // 不同尺寸的加载图标
  &.ant-spin-sm {
    .anticon {
      font-size: 16px;
    }
    
    .ant-spin-text {
      font-size: 12px;
    }
  }
  
  &.ant-spin-lg {
    .anticon {
      font-size: 32px;
    }
    
    .ant-spin-text {
      font-size: 16px;
    }
  }
}

// 全屏加载样式
.page-loading-fullscreen-wrapper {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: rgba(255, 255, 255, 0.65);
  
  .page-loading {
    min-height: auto;
    background-color: transparent;
    box-shadow: none;
  }
}

// 带有内容的加载状态
.ant-spin-nested-loading {
  > .ant-spin {
    max-height: none;
    
    .ant-spin-dot {
      margin: auto;
    }
  }
  
  > .ant-spin-container {
    transition: opacity 0.3s;
    
    &.ant-spin-blur {
      opacity: 0.5;
      filter: blur(0.5px);
      pointer-events: none;
    }
  }
}

// 暗色主题支持
[data-theme='dark'] {
  .page-loading {
    .ant-spin-text {
      color: rgba(255, 255, 255, 0.65);
    }
  }
  
  .page-loading-fullscreen-wrapper {
    background-color: rgba(0, 0, 0, 0.65);
  }
}

// 响应式布局
@media screen and (max-width: 576px) {
  .page-loading {
    min-height: 150px;
    
    &.ant-spin-lg {
      .anticon {
        font-size: 28px;
      }
      
      .ant-spin-text {
        font-size: 14px;
      }
    }
  }
}

// 自定义加载动画
.page-loading-custom {
  .loading-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: #1890ff;
    margin: 0 4px;
    animation: loading-dot-animation 1.4s infinite ease-in-out both;
    
    &:nth-child(1) {
      animation-delay: -0.32s;
    }
    
    &:nth-child(2) {
      animation-delay: -0.16s;
    }
  }
}

@keyframes loading-dot-animation {
  0%, 80%, 100% {
    transform: scale(0);
  }
  40% {
    transform: scale(1);
  }
}